package com.ruoyi.etp.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.etp.mapper.EtpRecordingDeviceStatsMapper;
import com.ruoyi.etp.domain.EtpRecordingDeviceStats;
import com.ruoyi.etp.service.IEtpRecordingDeviceStatsService;

/**
 * 员工设备使用情况Service业务层处理
 * 
 * @author xmj
 * @date 2025-09-12
 */
@Service
public class EtpRecordingDeviceStatsServiceImpl implements IEtpRecordingDeviceStatsService 
{
    @Autowired
    private EtpRecordingDeviceStatsMapper etpRecordingDeviceStatsMapper;

    /**
     * 查询员工设备使用情况
     * 
     * @param id 员工设备使用情况主键
     * @return 员工设备使用情况
     */
    @Override
    public EtpRecordingDeviceStats selectEtpRecordingDeviceStatsById(Long id)
    {
        return etpRecordingDeviceStatsMapper.selectEtpRecordingDeviceStatsById(id);
    }

    /**
     * 查询员工设备使用情况列表
     * 
     * @param etpRecordingDeviceStats 员工设备使用情况
     * @return 员工设备使用情况
     */
    @Override
    public List<EtpRecordingDeviceStats> selectEtpRecordingDeviceStatsList(EtpRecordingDeviceStats etpRecordingDeviceStats)
    {
        return etpRecordingDeviceStatsMapper.selectEtpRecordingDeviceStatsList(etpRecordingDeviceStats);
    }

    /**
     * 新增员工设备使用情况
     * 
     * @param etpRecordingDeviceStats 员工设备使用情况
     * @return 结果
     */
    @Override
    public int insertEtpRecordingDeviceStats(EtpRecordingDeviceStats etpRecordingDeviceStats)
    {
        return etpRecordingDeviceStatsMapper.insertEtpRecordingDeviceStats(etpRecordingDeviceStats);
    }

    /**
     * 修改员工设备使用情况
     * 
     * @param etpRecordingDeviceStats 员工设备使用情况
     * @return 结果
     */
    @Override
    public int updateEtpRecordingDeviceStats(EtpRecordingDeviceStats etpRecordingDeviceStats)
    {
        etpRecordingDeviceStats.setUpdateTime(DateUtils.getNowDate());
        return etpRecordingDeviceStatsMapper.updateEtpRecordingDeviceStats(etpRecordingDeviceStats);
    }

    /**
     * 批量删除员工设备使用情况
     * 
     * @param ids 需要删除的员工设备使用情况主键
     * @return 结果
     */
    @Override
    public int deleteEtpRecordingDeviceStatsByIds(Long[] ids)
    {
        return etpRecordingDeviceStatsMapper.deleteEtpRecordingDeviceStatsByIds(ids);
    }

    /**
     * 删除员工设备使用情况信息
     * 
     * @param id 员工设备使用情况主键
     * @return 结果
     */
    @Override
    public int deleteEtpRecordingDeviceStatsById(Long id)
    {
        return etpRecordingDeviceStatsMapper.deleteEtpRecordingDeviceStatsById(id);
    }
}
